package cn.wolfcode.trip.base.util;

import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class JSONResult {

    private boolean success = true;
    //失败时返回的错误信息
    private String msg;
    //成功是返回的数据
    private Object result;

    //出错时,再调用设置错误信息
    public JSONResult mark(String msg){
        this.success = false;
        this.msg = msg;
        return this;

    }

}
